package com.jrx.anytxn.transaction.dto.payment;

import com.jrx.anytxn.transaction.dto.common.CommonReq;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.*;
import java.math.BigDecimal;

/**
 * 账单分期试算请求实体
 */
@ApiModel(value = "账单分期试算请求实体", description = "账单分期试算请求实体")
public class LoanStagingTrailReq extends CommonReq {

    /**
     * 产品编号
     */
    @ApiModelProperty(value = "产品编号")
    @NotBlank
    @Size(max=32, message = "产品编号不能超过32位")
    private String productId;

    /**
     * 还款方式
     */
    @NotEmpty (message = "还款方式不允许空")
    @ApiModelProperty(value = "还款方式",required = true)
    @Size(max=6, message = "还款方式不能超过6位")
    private String amortMethod;

    /**
     * 贷款期数
     */
    @ApiModelProperty(value = "贷款期数",required = true)
    @NotNull (message = "贷款期数不允许为空")
    @Min(value=0,message="贷款期数必须大于0且是正整数")
    private Integer tenor;

    @ApiModelProperty(value = "分期订单号")
    private String stagingLoanId;

    @ApiModelProperty(value = "分期金额")
    private BigDecimal stagingAmount;

    public String getProductId() {
        return productId;
    }

    public void setProductId(String productId) {
        this.productId = productId;
    }

    public String getAmortMethod() {
        return amortMethod;
    }

    public void setAmortMethod(String amortMethod) {
        this.amortMethod = amortMethod;
    }

    public Integer getTenor() {
        return tenor;
    }

    public void setTenor(Integer tenor) {
        this.tenor = tenor;
    }

    public BigDecimal getStagingAmount() {
        return stagingAmount;
    }

    public void setStagingAmount(BigDecimal stagingAmount) {
        this.stagingAmount = stagingAmount;
    }

    public String getStagingLoanId() {
        return stagingLoanId;
    }

    public void setStagingLoanId(String stagingLoanId) {
        this.stagingLoanId = stagingLoanId;
    }
}
